package sdk3
{
    import mx.core.UIComponent;
    import mx.printing.*;

	public class c_PRINT extends FlexPrintJob
	{
		public function c_PRINT()
		{
		}

        // Create a PrintJob instance.
        public function OBJECT(DISPLAY_OBJECT:UIComponent):void
        {
            // Start the print job.
            // if (this.RECHNUNGSWESEN() != true) return;

			this.printAsBitmap = false;

            // Add the object to print. Do not scale it.
            this.addObject(DISPLAY_OBJECT, FlexPrintJobScaleType.MATCH_WIDTH);
            /**
			MATCH_WIDTH
			(Default) Scales the object to fill the available page width. If the resulting object height exceeds the page height, the output spans multiple pages.
			MATCH_HEIGHT
			Scales the object to fill the available page height. If the resulting object width exceeds the page width, the output spans multiple pages.
			SHOW_ALL
			Scales the object to fit on a single page, filling one dimension; that is, it selects the smaller of the MATCH_WIDTH or MATCH_HEIGHT scale types.
			FILL_PAGE
			Scales the object to fill at least one page completely; that is, it selects the larger of the MATCH_WIDTH or MATCH_HEIGHT scale types.
			NONE
			Does not scale the output. The printed page has the same dimensions as the object on the screen. If the object height, width, or both dimensions exceed the page width or height, the output spans multiple pages.
            **/

            // Send the job to the printer.
            this.send();
        }
/* 
	    public function SPRITE(SPRITE_TO_PRINT:Sprite)
	    {
	        myPrintJob.start();
	        myPrintJob.addPage(SPRITE_TO_PRINT);
	        myPrintJob.send();
	    }
 */
	}
}


